Meta-tracing makes a fast Racket
نویسندگان
چکیده
Tracing just-in-time (JIT) compilers record and optimize the instruction sequences they observe at runtime. With some modifications, a tracing JIT can perform well even when the executed program is itself an interpreter, an approach called meta-tracing. The advantage of meta-tracing is that it separates the concern of JIT compilation from language implementation, enabling the same JIT compiler to be used with many different languages. The RPython meta-tracing JIT compiler has enabled the efficient interpretation of several dynamic languages including Python (PyPy), Prolog, and Smalltalk. In this paper we present initial findings in applying the RPython JIT to Racket. Racket comes from the Scheme family of programming languages for which there are mature static optimizing compilers. We present the result of spending just a couple person-months implementing and tuning an implementation of Racket written in RPython. The results are promising, with a geometric mean equal to Racket’s performance and within a factor of 2 slower than Gambit and Larceny on a collection of standard Scheme benchmarks. The results on individual benchmarks vary widely. On the positive side, our interpreter is sometimes up to two to five times faster than Gambit, three times faster than Larceny, and two orders of magnitude faster than the Racket JIT compiler when making heavy use of continuations. On the negative side, our interpreter is sometimes two times slower than Racket, eight times slower than Gambit, and six times slower than Larceny.
منابع مشابه
Meta-Meta-Programming Generating C++ Template Metaprograms with Racket Macros
Domain specific languages embedded in C++ (EDSLs) often use the techniques of template metaprogramming and expression templates. However, these techniques can require verbose code and introduce maintenance and debugging challenges. This paper presents a tool written in Racket for generating C++ programs, paying particular attention to the challenges of metaprogramming. The code generator uses R...
متن کاملEffect of the racket mass and the rate of strokes on kinematics and kinetics in the table tennis topspin backhand.
The purpose of this study was to investigate the effect of the racket mass and the rate of strokes on the kinematics and kinetics of the trunk and the racket arm in the table tennis topspin backhand. Eight male Division I collegiate table tennis players hit topspin backhands against topspin balls projected at 75 balls · min(-1) and 35 balls · min(-1) using three rackets varying in mass of 153.5...
متن کاملImplementing Python for DrRacket
The Python programming language is becoming increasingly popular in a variety of areas, most notably among novice programmers. On the other hand, Racket and other Scheme dialects are considered excellent vehicles for introducing Computer Science concepts. This paper presents an implementation of Python for Racket and the DrRacket IDE. This allows Python programmers to use Racket libraries and v...
متن کاملA General Architecture for Heterogeneous Language Engineering and Projectional Editor Support
Tool support for language engineering has typically prioritises concrete syntax over abstract syntax by providing meta-languages for expressing concrete syntax and then mapping concrete to abstract structures. Text-based languages are usually specified using a BNF-like language used to generate a syntax-aware editor that includes features such as keyword completion. Similarly, graphical languag...
متن کاملEfficient Applicative Programming Environments for Computer Vision Applications Integration and Use of the VIGRA Library in Racket
Modern software development approaches, like agile software engineering, require adequate tools and languages to support the development in a clearly structured way. At best, they shall provide a steep learning curve as well as interactive development environments. In the field of computer vision, there is a major interest for both, general research and education e.g. of undergraduate students....
متن کامل